/////////////////////////////////////////////////////////////////////
//
// OposPtr.h
//
//   POS Printer header file for OPOS Applications.
//
// Modification history
// ------------------------------------------------------------------
// 1995-12-08 OPOS Release 1.0                                   CRM
// 1996-04-22 OPOS Release 1.1                                   CRM
//   Add CapCharacterSet constants.
//   Add ErrorLevel constants.
//   Add TransactionPrint's Control constants.
// 1997-06-04 OPOS Release 1.2                                   CRM
//   Remove PTR_RP_NORMAL_ASYNC.
//   Add more barcode symbologies.
// 1998-03-06 OPOS Release 1.3                                   CRM
//   Add more PrintTwoNormal constants.
// 2000-09-24 OPOS Release 1.5                             EPSON/BKS
//   Add CapRecMarkFeed and MarkFeed's Type constants.
//   Add ChangePrintSide constants.
//   Add StatusUpdateEvent constants.
//   Add ResultCodeExtended constants.
//   Add CapXxxCartridgeSensor and XxxCartridgeState constants.
//   Add CartridgeNotify constants.
//   Add CapCharacterset and CharacterSet constants for UNICODE.
// 2003-05-29 OPOS Release 1.7                                   CRM
//   Add more RotatePrint's Rotation PTR_RP_* constants.
// 2004-03-22 OPOS Release 1.8                                   CRM
//   Add more constants for PrintBarCode method and StatusUpdateEvent.
// 2004-10-26 Add "CharacterSet" ANSI constant (from 1.5).       CRM
// 2005-04-29 OPOS Release 1.9                                   CRM
//   Add PageModeDescriptor and PageModePrintDirection constants.
//   Add PageModePrint's Control constants.
// 2006-03-15 OPOS Release 1.10                                  CRM
//   Add PrintMemoryBitmap constants.
// 2008-08-30 OPOS Release 1.12                                  CRM
//   Add more constants for PrintBarCode method.
// 2009-10-02 OPOS Release 1.13                                  CRM
//   Add CapRecRuledLine and CapSlpRuledLine constants.
//   Add DrawRuledLine constants.
//   Add more constants for PrintBarCode method.
// 2011-04-07                                                    EPO
//   Converted to Pascal by Eric Orilla
//
/////////////////////////////////////////////////////////////////////

unit oposptr;

interface

const

/////////////////////////////////////////////////////////////////////
// Printer Station Constants
/////////////////////////////////////////////////////////////////////

  PTR_S_JOURNAL        : Longint     = 1;
  PTR_S_RECEIPT        : Longint     = 2;
  PTR_S_SLIP           : Longint     = 4;

  PTR_S_JOURNAL_RECEIPT    : Longint     = $0003;
  PTR_S_JOURNAL_SLIP       : Longint     = $0005;
  PTR_S_RECEIPT_SLIP       : Longint     = $0006;

  PTR_TWO_RECEIPT_JOURNAL  : Longint     = $8003; // (added in 1.3)
  PTR_TWO_SLIP_JOURNAL     : Longint     = $8005; // (added in 1.3)
  PTR_TWO_SLIP_RECEIPT     : Longint     = $8006; // (added in 1.3)


/////////////////////////////////////////////////////////////////////
// "CapCharacterSet" Property Constants (added in 1.1)
/////////////////////////////////////////////////////////////////////

  PTR_CCS_ALPHA        : Longint     =   1;
  PTR_CCS_ASCII        : Longint     = 998;
  PTR_CCS_KANA         : Longint     =  10;
  PTR_CCS_KANJI        : Longint     =  11;
  PTR_CCS_UNICODE      : Longint     = 997; // (added in 1.5)


/////////////////////////////////////////////////////////////////////
// "CharacterSet" Property Constants
/////////////////////////////////////////////////////////////////////

  PTR_CS_UNICODE       : Longint     = 997; // (added in 1.5)
  PTR_CS_ASCII         : Longint     = 998;
  PTR_CS_WINDOWS       : Longint     = 999;
  PTR_CS_ANSI          : Longint     = 999;


/////////////////////////////////////////////////////////////////////
// "ErrorLevel" Property Constants (added in 1.1)
/////////////////////////////////////////////////////////////////////

  PTR_EL_NONE          : Longint     = 1;
  PTR_EL_RECOVERABLE   : Longint     = 2;
  PTR_EL_FATAL         : Longint     = 3;


/////////////////////////////////////////////////////////////////////
// "MapMode" Property Constants
/////////////////////////////////////////////////////////////////////

  PTR_MM_DOTS          : Longint     = 1;
  PTR_MM_TWIPS         : Longint     = 2;
  PTR_MM_ENGLISH       : Longint     = 3;
  PTR_MM_METRIC        : Longint     = 4;


/////////////////////////////////////////////////////////////////////
// "CapXxxColor" Property Constants
/////////////////////////////////////////////////////////////////////

  PTR_COLOR_PRIMARY      : Longint     = $00000001;
  PTR_COLOR_CUSTOM1      : Longint     = $00000002;
  PTR_COLOR_CUSTOM2      : Longint     = $00000004;
  PTR_COLOR_CUSTOM3      : Longint     = $00000008;
  PTR_COLOR_CUSTOM4      : Longint     = $00000010;
  PTR_COLOR_CUSTOM5      : Longint     = $00000020;
  PTR_COLOR_CUSTOM6      : Longint     = $00000040;
  PTR_COLOR_CYAN         : Longint     = $00000100;
  PTR_COLOR_MAGENTA      : Longint     = $00000200;
  PTR_COLOR_YELLOW       : Longint     = $00000400;
  PTR_COLOR_FULL         : Longword    = $80000000;


/////////////////////////////////////////////////////////////////////
// "CapXxxCartridgeSensor" and  "XxxCartridgeState" Property Constants
//   (added in 1.5)
/////////////////////////////////////////////////////////////////////

  PTR_CART_UNKNOWN         : Longint     = $10000000;
  PTR_CART_OK              : Longint     = $00000000;
  PTR_CART_REMOVED         : Longint     = $00000001;
  PTR_CART_EMPTY           : Longint     = $00000002;
  PTR_CART_NEAREND         : Longint     = $00000004;
  PTR_CART_CLEANING        : Longint     = $00000008;


/////////////////////////////////////////////////////////////////////
// "CartridgeNotify" Property Constants (added in 1.5)
/////////////////////////////////////////////////////////////////////

  PTR_CN_DISABLED        : Longint     = $00000000;
  PTR_CN_ENABLED         : Longint     = $00000001;


/////////////////////////////////////////////////////////////////////
// "PageModeDescriptor" Property Constants (added in 1.9)
/////////////////////////////////////////////////////////////////////

  PTR_PM_BITMAP         : Longint     = $00000001;
  PTR_PM_BARCODE        : Longint     = $00000002;
  PTR_PM_BM_ROTATE      : Longint     = $00000004;
  PTR_PM_BC_ROTATE      : Longint     = $00000008;
  PTR_PM_OPAQUE         : Longint     = $00000010;


/////////////////////////////////////////////////////////////////////
// "PageModePrintDirection" Property Constants (added in 1.9)
/////////////////////////////////////////////////////////////////////

  PTR_PD_LEFT_TO_RIGHT : Longint     = 1;
  PTR_PD_BOTTOM_TO_TOP : Longint     = 2;
  PTR_PD_RIGHT_TO_LEFT : Longint     = 3;
  PTR_PD_TOP_TO_BOTTOM : Longint     = 4;


/////////////////////////////////////////////////////////////////////
// "CutPaper" Method Constant
/////////////////////////////////////////////////////////////////////

  PTR_CP_FULLCUT       : Longint     = 100;


/////////////////////////////////////////////////////////////////////
// "PageModePrint" Method: "Control" Parameter Constants (added in 1.9)
/////////////////////////////////////////////////////////////////////

  PTR_PM_PAGE_MODE      : Longint     = 1;
  PTR_PM_PRINT_SAVE     : Longint     = 2;
  PTR_PM_NORMAL         : Longint     = 3;
  PTR_PM_CANCEL         : Longint     = 4;


/////////////////////////////////////////////////////////////////////
// "PrintBarCode" Method Constants:
/////////////////////////////////////////////////////////////////////

//** "Alignment" Parameter
//     Either the distance from the left-most print column to the start
//     of the bar code, or one of the following:

  PTR_BC_LEFT          : Longint     = -1;
  PTR_BC_CENTER        : Longint     = -2;
  PTR_BC_RIGHT         : Longint     = -3;

//** "TextPosition" Parameter

  PTR_BC_TEXT_NONE     : Longint     = -11;
  PTR_BC_TEXT_ABOVE    : Longint     = -12;
  PTR_BC_TEXT_BELOW    : Longint     = -13;

//** "Symbology" Parameter:

//    - One dimensional symbologies
  PTR_BCS_UPCA         : Longint     = 101;  // Digits
  PTR_BCS_UPCE         : Longint     = 102;  // Digits
  PTR_BCS_JAN8         : Longint     = 103;  // : Longint     = EAN 8
  PTR_BCS_EAN8         : Longint     = 103;  // : Longint     = JAN 8 (added in 1.2)
  PTR_BCS_JAN13        : Longint     = 104;  // : Longint     = EAN 13
  PTR_BCS_EAN13        : Longint     = 104;  // : Longint     = JAN 13 (added in 1.2)
  PTR_BCS_TF           : Longint     = 105;  // (Discrete 2 of 5) Digits
  PTR_BCS_ITF          : Longint     = 106;  // (Interleaved 2 of 5) Digits
  PTR_BCS_Codabar      : Longint     = 107;  // Digits, -, $, :, /, ., +;
                                        //   4 start/stop characters
                                        //   (a, b, c, d)
  PTR_BCS_Code39       : Longint     = 108;  // Alpha, Digits, Space, -, .,
                                        //   $, /, +, %; start/stop (*)
                                        // Also has Full ASCII feature
  PTR_BCS_Code93       : Longint     = 109;  // Same characters as Code 39
  PTR_BCS_Code128      : Longint     = 110;  // 128 data characters

//    - One dimensional symbologies (added in 1.2)
  PTR_BCS_UPCA_S       : Longint     = 111;  // UPC-A with supplemental
                                        //   barcode
  PTR_BCS_UPCE_S       : Longint     = 112;  // UPC-E with supplemental
                                        //   barcode
  PTR_BCS_UPCD1        : Longint     = 113;  // UPC-D1
  PTR_BCS_UPCD2        : Longint     = 114;  // UPC-D2
  PTR_BCS_UPCD3        : Longint     = 115;  // UPC-D3
  PTR_BCS_UPCD4        : Longint     = 116;  // UPC-D4
  PTR_BCS_UPCD5        : Longint     = 117;  // UPC-D5
  PTR_BCS_EAN8_S       : Longint     = 118;  // EAN 8 with supplemental
                                        //   barcode
  PTR_BCS_EAN13_S      : Longint     = 119;  // EAN 13 with supplemental
                                        //   barcode
  PTR_BCS_EAN128       : Longint     = 120;  // EAN 128
  PTR_BCS_OCRA         : Longint     = 121;  // OCR "A"
  PTR_BCS_OCRB         : Longint     = 122;  // OCR "B"

//    - One dimensional symbologies (added in 1.8)
  PTR_BCS_Code128_Parsed: Longint     =123;  // Code 128 with parsing
//        The following RSS constants deprecated in 1.12.
//        Instead use the GS1DATABAR constants below.
  PTR_BCS_RSS14        : Longint     = 131;  // Reduced Space Symbology - 14 digit GTIN
  PTR_BCS_RSS_EXPANDED : Longint     = 132;  // RSS - 14 digit GTIN plus additional fields

//    - One dimensional symbologies (added in 1.12)
  PTR_BCS_GS1DATABAR    : Longint     =131;  // GS1 DataBar Omnidirectional
  PTR_BCS_GS1DATABAR_E  : Longint     =132;  // GS1 DataBar Expanded
  PTR_BCS_GS1DATABAR_S  : Longint     =133;  // GS1 DataBar Stacked Omnidirectional
  PTR_BCS_GS1DATABAR_E_S: Longint     =134;  // GS1 DataBar Expanded Stacked

//    - Two dimensional symbologies
  PTR_BCS_PDF417       : Longint     = 201;
  PTR_BCS_MAXICODE     : Longint     = 202;

//    - Two dimensional symbologies (added in 1.13)
  PTR_BCS_DATAMATRIX   : Longint     = 203;  // Data Matrix
  PTR_BCS_QRCODE       : Longint     = 204;  // QR Code
  PTR_BCS_UQRCODE      : Longint     = 205;  // Micro QR Code
  PTR_BCS_AZTEC        : Longint     = 206;  // Aztec
  PTR_BCS_UPDF417      : Longint     = 207;  // Micro PDF 417

//    - Start of Printer-Specific bar code symbologies
  PTR_BCS_OTHER        : Longint     = 501;


/////////////////////////////////////////////////////////////////////
// "PrintBitmap" and "PrintMemoryBitmap" Method Constants:
/////////////////////////////////////////////////////////////////////

//** "Width" Parameter
//     Either bitmap width or:

  PTR_BM_ASIS          : Longint     = -11;  // One pixel per printer dot

//** "Alignment" Parameter
//     Either the distance from the left-most print column to the start
//     of the bitmap, or one of the following:

  PTR_BM_LEFT          : Longint     = -1;
  PTR_BM_CENTER        : Longint     = -2;
  PTR_BM_RIGHT         : Longint     = -3;

//** "Type" Parameter ("PrintMemoryBitmap" only)
  PTR_BMT_BMP          : Longint     = 1;
  PTR_BMT_JPEG         : Longint     = 2;
  PTR_BMT_GIF          : Longint     = 3;


/////////////////////////////////////////////////////////////////////
// "RotatePrint" Method: "Rotation" Parameter Constants
// "RotateSpecial" Property Constants
/////////////////////////////////////////////////////////////////////

  PTR_RP_NORMAL        : Longint     = $0001;
  PTR_RP_RIGHT90       : Longint     = $0101;
  PTR_RP_LEFT90        : Longint     = $0102;
  PTR_RP_ROTATE180     : Longint     = $0103;

// For "RotatePrint", one or both of the following values may be
// ORed with one of the above values.
  PTR_RP_BARCODE       : Longint     = $1000; // (added in 1.7)
  PTR_RP_BITMAP        : Longint     = $2000; // (added in 1.7)


/////////////////////////////////////////////////////////////////////
// "SetLogo" Method: "Location" Parameter Constants
/////////////////////////////////////////////////////////////////////

  PTR_L_TOP            : Longint     = 1;
  PTR_L_BOTTOM         : Longint     = 2;


/////////////////////////////////////////////////////////////////////
// "TransactionPrint" Method: "Control" Parameter Constants (added in 1.1)
/////////////////////////////////////////////////////////////////////

  PTR_TP_TRANSACTION   : Longint     = 11;
  PTR_TP_NORMAL        : Longint     = 12;


/////////////////////////////////////////////////////////////////////
// "MarkFeed" Method: "Type" Parameter Constants (added in 1.5)
// "CapRecMarkFeed" Property Constants (added in 1.5)
/////////////////////////////////////////////////////////////////////

  PTR_MF_TO_TAKEUP     : Longint     = 1;
  PTR_MF_TO_CUTTER     : Longint     = 2;
  PTR_MF_TO_CURRENT_TOF: Longint     = 4;
  PTR_MF_TO_NEXT_TOF   : Longint     = 8;


/////////////////////////////////////////////////////////////////////
// "ChangePrintSide" Method: "Side" Parameter Constants (added in 1.5)
/////////////////////////////////////////////////////////////////////

  PTR_PS_UNKNOWN       : Longint     = 0;
  PTR_PS_SIDE1         : Longint     = 1;
  PTR_PS_SIDE2         : Longint     = 2;
  PTR_PS_OPPOSITE      : Longint     = 3;


/////////////////////////////////////////////////////////////////////
// "CapRecRuledLine" and "CapSlpRuledLine" Property Constants
// "DrawRuledLine" Method: "LineDirection" Parameter Constants
// (added in 1.13)
/////////////////////////////////////////////////////////////////////

  PTR_RL_HORIZONTAL : Longint     = 1;
  PTR_RL_VERTICAL   : Longint     = 2;


/////////////////////////////////////////////////////////////////////
// "DrawRuledLine" Method: "LineStyle" Parameter Constants
// (added in 1.13)
/////////////////////////////////////////////////////////////////////

  PTR_LS_SINGLE_SOLID_LINE : Longint     = 1;
  PTR_LS_DOUBLE_SOLID_LINE : Longint     = 2;
  PTR_LS_BROKEN_LINE       : Longint     = 3;
  PTR_LS_CHAIN_LINE        : Longint     = 4;


/////////////////////////////////////////////////////////////////////
// "StatusUpdateEvent" Event: "Data" Parameter Constants
/////////////////////////////////////////////////////////////////////

  PTR_SUE_COVER_OPEN              : Longint     = 11;
  PTR_SUE_COVER_OK                : Longint     = 12;
  PTR_SUE_JRN_COVER_OPEN          : Longint     = 60;  // (added in 1.8)
  PTR_SUE_JRN_COVER_OK            : Longint     = 61;  // (added in 1.8)
  PTR_SUE_REC_COVER_OPEN          : Longint     = 62;  // (added in 1.8)
  PTR_SUE_REC_COVER_OK            : Longint     = 63;  // (added in 1.8)
  PTR_SUE_SLP_COVER_OPEN          : Longint     = 64;  // (added in 1.8)
  PTR_SUE_SLP_COVER_OK            : Longint     = 65;  // (added in 1.8)

  PTR_SUE_JRN_EMPTY               : Longint     = 21;
  PTR_SUE_JRN_NEAREMPTY           : Longint     = 22;
  PTR_SUE_JRN_PAPEROK             : Longint     = 23;

  PTR_SUE_REC_EMPTY               : Longint     = 24;
  PTR_SUE_REC_NEAREMPTY           : Longint     = 25;
  PTR_SUE_REC_PAPEROK             : Longint     = 26;

  PTR_SUE_SLP_EMPTY               : Longint     = 27;
  PTR_SUE_SLP_NEAREMPTY           : Longint     = 28;
  PTR_SUE_SLP_PAPEROK             : Longint     = 29;

  PTR_SUE_JRN_CARTRIDGE_EMPTY     : Longint     = 41; // (added in 1.5)
  PTR_SUE_JRN_CARTRIDGE_NEAREMPTY : Longint     = 42; // (added in 1.5)
  PTR_SUE_JRN_HEAD_CLEANING       : Longint     = 43; // (added in 1.5)
  PTR_SUE_JRN_CARTRIDGE_OK        : Longint     = 44; // (added in 1.5)

  PTR_SUE_REC_CARTRIDGE_EMPTY     : Longint     = 45; // (added in 1.5)
  PTR_SUE_REC_CARTRIDGE_NEAREMPTY : Longint     = 46; // (added in 1.5)
  PTR_SUE_REC_HEAD_CLEANING       : Longint     = 47; // (added in 1.5)
  PTR_SUE_REC_CARTRIDGE_OK        : Longint     = 48; // (added in 1.5)

  PTR_SUE_SLP_CARTRIDGE_EMPTY     : Longint     = 49; // (added in 1.5)
  PTR_SUE_SLP_CARTRIDGE_NEAREMPTY : Longint     = 50; // (added in 1.5)
  PTR_SUE_SLP_HEAD_CLEANING       : Longint     = 51; // (added in 1.5)
  PTR_SUE_SLP_CARTRIDGE_OK        : Longint     = 52; // (added in 1.5)

  PTR_SUE_IDLE                    : Longint     = 1001;


/////////////////////////////////////////////////////////////////////
// "ResultCodeExtended" Property Constants
/////////////////////////////////////////////////////////////////////

  OPOS_EPTR_COVER_OPEN            : Longint     = 201; // (Several)
  OPOS_EPTR_JRN_EMPTY             : Longint     = 202; // (Several)
  OPOS_EPTR_REC_EMPTY             : Longint     = 203; // (Several)
  OPOS_EPTR_SLP_EMPTY             : Longint     = 204; // (Several)
  OPOS_EPTR_SLP_FORM              : Longint     = 205; // EndRemoval
  OPOS_EPTR_TOOBIG                : Longint     = 206; // PrintBitmap
  OPOS_EPTR_BADFORMAT             : Longint     = 207; // PrintBitmap
  OPOS_EPTR_JRN_CARTRIDGE_REMOVED : Longint     = 208; // (Several) (added in 1.5)
  OPOS_EPTR_JRN_CARTRIDGE_EMPTY   : Longint     = 209; // (Several) (added in 1.5)
  OPOS_EPTR_JRN_HEAD_CLEANING     : Longint     = 210; // (Several) (added in 1.5)
  OPOS_EPTR_REC_CARTRIDGE_REMOVED : Longint     = 211; // (Several) (added in 1.5)
  OPOS_EPTR_REC_CARTRIDGE_EMPTY   : Longint     = 212; // (Several) (added in 1.5)
  OPOS_EPTR_REC_HEAD_CLEANING     : Longint     = 213; // (Several) (added in 1.5)
  OPOS_EPTR_SLP_CARTRIDGE_REMOVED : Longint     = 214; // (Several) (added in 1.5)
  OPOS_EPTR_SLP_CARTRIDGE_EMPTY   : Longint     = 215; // (Several) (added in 1.5)
  OPOS_EPTR_SLP_HEAD_CLEANING     : Longint     = 216; // (Several) (added in 1.5)


implementation

end.
